package com.mdd.front.service.impl.yangyangLeadingEnterprise;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.mdd.common.entity.yangyangLeadingEnterprise.TAppEnterpriseCreditRepair;
import com.mdd.common.mapper.yangyangLeadingEnterprise.TAppEnterpriseCreditRepairMapper;
import com.mdd.front.service.yangyangLeadingEnterprise.ITAppEnterpriseCreditRepairService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.List;
import java.util.Optional;

/**
 * 企业信用修复实现类
 * @author LikeAdmin
 */
@Service
public class TAppEnterpriseCreditRepairServiceImpl implements ITAppEnterpriseCreditRepairService {
        
    @Resource
    TAppEnterpriseCreditRepairMapper appEnterpriseCreditRepairMapper;

    @Override
    public List<TAppEnterpriseCreditRepair> selectList() {
        List<TAppEnterpriseCreditRepair> list = appEnterpriseCreditRepairMapper.selectList(new QueryWrapper<TAppEnterpriseCreditRepair>().orderByDesc("sort"));
        return Optional.ofNullable(list).orElse(new ArrayList<>());
    }
}
